Skip to content

chore: TSA-501 whats happening UI fixes#29920

Merged
joaosantos15 merged 5 commits into
mainfrom
TSA-501-whats-happening-ui-fixes
May 8, 2026
Merged

chore: TSA-501 whats happening UI fixes#29920
joaosantos15 merged 5 commits into
mainfrom
TSA-501-whats-happening-ui-fixes

Conversation

@joaosantos15
Copy link
Copy Markdown
Contributor

@joaosantos15 joaosantos15 commented May 8, 2026

Description

Small UI improvements to the What's Happening cards.
image

Changelog

CHANGELOG entry: no-changelog

Related issues

Fixes:

Manual testing steps

Feature: my feature name

  Scenario: user [verb for user action]
    Given [describe expected initial app state]

    When user [verb for user action]
    Then [describe expected outcome]

Screenshots/Recordings

Before

After

Pre-merge author checklist

Performance checks (if applicable)

  • I've tested on Android
    • Ideally on a mid-range device; emulator is acceptable
  • I've tested with a power user scenario
    • Use these power-user SRPs to import wallets with many accounts and tokens
  • I've instrumented key operations with Sentry traces for production performance metrics

For performance guidelines and tooling, see the Performance Guide.

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

Note

Low Risk
Low risk UI-only changes to card presentation and date formatting; main risk is minor regressions in layout or relative-time output for edge-case dates.

Overview
Updates the Homepage What’s Happening cards to simplify badges and improve the footer: the category badge is removed, impact badge styling is adjusted, and related assets are shown as up to 3 overlapping token icons plus a compact label (e.g., BTC +2) instead of multiple symbol pills.

Switches the card timestamp from a locale date to a relative time string via formatRelativeTime (with now support) and removes the unused formatShortDate helper. formatRelativeTime now returns an empty string for invalid dates, with new unit tests covering invalid inputs and minute/hour/day formatting.

Reviewed by Cursor Bugbot for commit 0aa690a. Bugbot is set up for automated code reviews on this repo. Configure here.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 8, 2026

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@metamaskbotv2 metamaskbotv2 Bot added the team-social-ai Social & AI team label May 8, 2026
@github-actions github-actions Bot added the pr-not-ready-for-e2e Skip E2E and block merging. Remove this label once the PR is ready to run the E2E tests. label May 8, 2026
@github-actions github-actions Bot added the size-M label May 8, 2026
@joaosantos15 joaosantos15 changed the title Tsa 501 whats happening UI fixes chore: TSA-501 whats happening UI fixes May 8, 2026
Copy link
Copy Markdown
Contributor

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 95dad60. Configure here.

Copy link
Copy Markdown
Contributor

@zone-live zone-live left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG!! 💪🏼

@joaosantos15 joaosantos15 removed the pr-not-ready-for-e2e Skip E2E and block merging. Remove this label once the PR is ready to run the E2E tests. label May 8, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 8, 2026

🔍 Smart E2E Test Selection

  • Selected E2E tags: SmokeWalletPlatform, SmokePerps
  • Selected Performance tags: None (no tests recommended)
  • Risk Level: low
  • AI Confidence: 85%
click to see 🤖 AI reasoning details

E2E Test Selection:
The changes are confined to the WhatsHappening section of the Homepage/Trending area:

  1. WhatsHappeningCard.tsx - UI refactor: removed category badge, changed date format from short date to relative time, changed asset display from text pills to stacked token logos using PerpsTokenLogo, simplified impact badge styling.
  2. marketInsightsFormatting.ts - Minor bug fix: added NaN guard for invalid dates in formatRelativeTime.
  3. formatDate.ts - Deleted (replaced by formatRelativeTime).
  4. Test files updated to match new behavior.

SmokeWalletPlatform is selected because the WhatsHappening section is part of the Trending discovery tab, which is explicitly covered by this tag (browsing content feeds including Tokens, Perps, Sites sections).

SmokePerps is selected because the card now uses PerpsTokenLogo component, and Perps is a section inside the Trending tab. Per the tag description: "Perps is also a section inside the Trending tab (SmokeWalletPlatform); changes to Perps views (headers, lists, full views) affect Trending." The PerpsTokenLogo integration creates a dependency on Perps rendering.

No other tags are warranted as these are purely UI display changes with no impact on: confirmations, accounts, network, swaps, staking, identity, browser, snaps, or other flows.

Performance Test Selection:
The changes are limited to UI display logic in the WhatsHappening card component - changing date formatting and asset icon display. These are minor rendering changes that don't affect list performance, data loading, app startup, or any other performance-critical paths. No performance tests are warranted.

View GitHub Actions results

@joaosantos15 joaosantos15 enabled auto-merge May 8, 2026 15:35
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented May 8, 2026

@joaosantos15 joaosantos15 added this pull request to the merge queue May 8, 2026
Merged via the queue into main with commit a62d62e May 8, 2026
156 of 157 checks passed
@joaosantos15 joaosantos15 deleted the TSA-501-whats-happening-ui-fixes branch May 8, 2026 16:36
@github-actions github-actions Bot locked and limited conversation to collaborators May 8, 2026
@metamaskbotv2 metamaskbotv2 Bot added the release-7.78.0 Issue or pull request that will be included in release 7.78.0 label May 8, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

release-7.78.0 Issue or pull request that will be included in release 7.78.0 size-M team-social-ai Social & AI team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants